<?php 

function isMobile(){
	$useragent = $_SERVER['HTTP_USER_AGENT'];
	return contains($useragent, "Mobile");
}

function contains($str1, $str2){
    return stristr($str1, $str2);
}

?>